<?php
namespace zake\foundation\able\reactor;


/**
 * Interface LoopAdaptAble
 * @package zake\foundation\able
 */
interface LoopAdaptAble
{

    /**
     *
     * @author liu.bin 2020-04-15 20:53
     */
    public function loop();


    public function addRead($resource,\Closure $handler);


    public function addWrite($resource,\Closure $handler);


    public function addTime($interval,\Closure $handler,$param=[]);


    public function addSignal($sigNo,\Closure $handler);


    public function removeRead($resource);


    public function removeWrite($resource);


    public function removeTime($timeId);


    public function removeSignal($sigNo);
}
